﻿using System;
using System.Collections.Generic;
using Sharp3DMath.Core;
using Sharp3DMath.Strokes;
using System.Text;

namespace LRSS
{
    public class FeaturesGenerator
    {
        public static StrokeFeaturesBase GetFeatures(Vector2F[] points)
        {
            Stroke stroke = new Stroke(points);
            GlobalGeometricFeatureGenerator generator = new GlobalGeometricFeatureGenerator();
            GlobalGeometricFeature globalFeatures = generator.LoadFrom(stroke);
            StrokeFeaturesBase featureBase = new StrokeFeaturesBase();
            featureBase.ComputeFeatures(globalFeatures);
            return featureBase;
        }
        public static StrokeFeaturesBase GetFeatures(Stroke stroke)
        {
            GlobalGeometricFeatureGenerator generator = new GlobalGeometricFeatureGenerator();
            GlobalGeometricFeature globalFeatures = generator.LoadFrom(stroke);
            StrokeFeaturesBase featureBase = new StrokeFeaturesBase();
            featureBase.ComputeFeatures(globalFeatures);
            return featureBase;
        }
    }
}
